package cc.surui.ui.fl 
{
	import cc.surui.mc.StartButton;
	import cc.surui.mc.StartButton_Disabled;
	import flash.display.MovieClip;
	import flash.display.SimpleButton;
	import flash.display.Sprite;
	
	/**
	 * 开始按钮
	 * @author Surui
	 */
	public class UIStartButton extends Sprite 
	{
		private var _startButton:SimpleButton = new StartButton();
		private var _startButtonDisabled:MovieClip = new StartButton_Disabled();
		private var _enable:Boolean;
		public function UIStartButton() 
		{
			this.addChild(_startButtonDisabled);
			this.addChild(_startButton);
		}
		
		public function get enable():Boolean 
		{
			return _enable;
		}
		
		public function set enable(value:Boolean):void 
		{
			_enable = value;
			if ( _enable ) {
				this.setChildIndex(_startButtonDisabled,0);
			} else {
				this.setChildIndex(_startButton,0);
			}
		}
		
	}

}